// -----------------------------------------------------------------------
// <copyright file="AppConfiguration.cs" company="Imar.Spaanjaars.Com">
//   Copyright 2008 - 2009 - Imar.Spaanjaars.Com. All rights reserved.
// </copyright>
// -----------------------------------------------------------------------

using System.Configuration;

namespace Spaanjaars.ContactManager.Dal
{
	/// <summary>
	/// The AppConfiguaration class contains read-only properties that are essentially short cuts to settings in the web.config file.
	/// </summary>
	public static class AppConfiguration
	{
		#region Public Properties

		/// <summary>Returns the connectionstring for the application.</summary>
		public static string ConnectionString
		{
			get
			{
				return ConfigurationManager.ConnectionStrings[ConnectionStringName].ConnectionString;
			}
		}
		/// <summary>Returns the name of the current connectionstring for the application.</summary>
		public static string ConnectionStringName
		{
			get
			{
				return ConfigurationManager.AppSettings["ConnectionStringName"];
			}
		}
		#endregion
	}
}